git subtree
命令手册Tool to manage project dependencies as subprojects. More information: https://manpages.debian.org/testing/git-man/git-subtree.1.en.html.
git subtree add --prefix={{path/to/directory/}} --squash {{repository_url}} {{branch_name}}
git subtree pull --prefix={{path/to/directory/}} {{repository_url}} {{branch_name}}
git subtree merge --prefix={{path/to/directory/}} --squash {{repository_url}} {{branch_name}}
git subtree push --prefix={{path/to/directory/}} {{repository_url}} {{branch_name}}
git subtree split --prefix={{path/to/directory/}} {{repository_url}} -b {{branch_name}}